package cn.dujc.superkid.fragment.research;

import android.os.Bundle;
import android.text.Html;
import android.widget.TextView;

import cn.dujc.core.ui.BaseFragment;
import cn.dujc.superkid.R;
import cn.dujc.superkid.api.HttpHelper;
import cn.dujc.superkid.api.QMap;
import cn.dujc.superkid.api.Result;
import cn.dujc.superkid.api.ResultCallBack;
import cn.dujc.superkid.bean.IsSignInResult;

/**
 * @author du
 * date 2018/8/2 上午12:11
 */
//研究院介绍
public class AboutResearchFragment extends BaseFragment {
    private TextView tv_title;
    @Override
    public int getViewId() {
        return R.layout.fragment_aboutresearch;
    }

    @Override
    public void initBasic(Bundle savedInstanceState) {
        tv_title= (TextView) findViewById(R.id.tv_title);
        getDate();
    }

    private void getDate() {
        HttpHelper.getHome().about(QMap.build()
                .create()).enqueue(new ResultCallBack<Result<String>>(mActivity) {
            @Override
            public void onSuccessCallback(int code, Result<String> body) {
                final String data = body.getData();
                tv_title.setText(Html.fromHtml(data));
            }
        });
    }


}
